import 'dart:convert';

BookFolders bookFoldersFromJson(String str) => BookFolders.fromJson(json.decode(str));

String bookFoldersToJson(BookFolders data) => json.encode(data.toJson());

class BookFolders {
    BookFolders({
        this.allFolder,
    });

    List<AllFolder>? allFolder;

    factory BookFolders.fromJson(Map<String, dynamic> json) => BookFolders(
        allFolder: json["allFolder"]!=null ? List<AllFolder>.from(json["allFolder"].map((x) => AllFolder.fromJson(x))) : [],
    );

    Map<String, dynamic> toJson() => {
        "allFolder": allFolder!=null ? List<dynamic>.from(allFolder!.map((x) => x.toJson())) : null,
    };
}

class AllFolder {
    AllFolder({
         this.id,
         this.folderName,
        this.bookCount,
    });

    String? id;
    String? folderName;
    int? bookCount;

    factory AllFolder.fromJson(Map<String, dynamic> json) => AllFolder(
        id: json["id"],
        folderName: json["folderName"],
        bookCount: json["bookCount"],
    );

    Map<String, dynamic> toJson() => {
        "id": id,
        "folderName": folderName,
        "bookCount": bookCount,
    };
}
